home *** CD-ROM | disk | FTP | other *** search
- module DrBob42
- {
- interface Rates
- {
- float interest_rate();
- };
-
-
- interface Account
- {
- float balance();
- float get_rates(in Rates myRates);
- };
-
-
- struct AccountError
- {
- float Balance;
- string ErrorMessage;
- };
-
- exception AccountException
- {
- AccountError Error;
- };
-
-
- interface MyAccount: Account
- {
- void deposit(in float amount);
- void withdraw(in float amount) raises(AccountException);
- };
-
-
- typedef string Identifier;
-
- enum EnumType
- {
- first,
- second,
- third
- };
-
- struct StructType
- {
- short s;
- long l;
- Identifier i;
- };
-
- union UnionType switch (long)
- {
- case -1: short s;
- case 0: long l;
- case 1: Identifier i;
- };
-
- const unsigned long ArraySize = 3;
-
- typedef StructType StructArray[ArraySize];
-
- typedef sequence<StructType> StructSequence;
-
- interface ADT
- {
- void test(in Identifier one, in EnumType two, in StructType three,
- in UnionType four, in StructArray five, in StructSequence six);
- };
-
- typedef sequence<unsigned long, 5> IntSeq;
-
- interface SeqAccount
- {
- float balance(in IntSeq mySeq);
- };
-
- };
-